window.onload = function(){

    var company = document.getElementById('company');
    var industry = document.getElementById('industry');
    var media = document.getElementById('media');
    var thematic = document.getElementById('thematic');


    var Company = document.getElementById('Company');
    var Industry = document.getElementById('Industry');
    var Media = document.getElementById('Media');
    var Thematic = document.getElementById('Thematic');


    var News = document.getElementById('News');

    var ull = document.getElementById('ull');
    company.addEventListener('click',

        function(){
            Company.style.display = 'block';
            Industry.style.display = 'none';
            Media.style.display = 'none';
            Thematic.style.display = 'none';
            company.firstChild.style.color = "#181947";
            company.firstChild.style.backgroundColor = "white";
            industry.firstChild.style.color = null;
            industry.firstChild.style.backgroundColor = null;
            media.firstChild.style.color = null;
            media.firstChild.style.backgroundColor = null;
            thematic.firstChild.style.color = null;
            thematic.firstChild.style.backgroundColor = null;
        }

    )
    industry.addEventListener('click',

        function(){
            Company.style.display = 'none';
            Industry.style.display = 'block';
            Media.style.display = 'none';
            Thematic.style.display = 'none';
            industry.firstChild.style.color = "#181947";
            industry.firstChild.style.backgroundColor = "white";
            company.firstChild.style.color = null;
            company.firstChild.style.backgroundColor = null;
            media.firstChild.style.color = null;
            media.firstChild.style.backgroundColor = null;
            thematic.firstChild.style.color = null;
            thematic.firstChild.style.backgroundColor = null;
        }

    )
    media.addEventListener('click',

        function(){
            Company.style.display = 'none';
            Industry.style.display = 'none';
            Media.style.display = 'block';
            Thematic.style.display = 'none';
            media.firstChild.style.color = "#181947";
            media.firstChild.style.backgroundColor = "white";
            company.firstChild.style.color = null;
            company.firstChild.style.backgroundColor = null;
            industry.firstChild.style.color = null;
            industry.firstChild.style.backgroundColor = null;
            thematic.firstChild.style.color = null;
            thematic.firstChild.style.backgroundColor = null;

        }

    )
    thematic.addEventListener('click',

        function(){
            Company.style.display = 'none';
            Industry.style.display = 'none';
            Media.style.display = 'none';
            Thematic.style.display = 'block';
            thematic.firstChild.style.color = "#181947";
            thematic.firstChild.style.backgroundColor = "white";
            company.firstChild.style.color = null;
            company.firstChild.style.backgroundColor = null;
            media.firstChild.style.color = null;
            media.firstChild.style.backgroundColor = null;
            industry.firstChild.style.color = null;
            industry.firstChild.style.backgroundColor = null;
        }

    )
    var close = document.getElementById('close');
    var next = document.getElementById("next");
    var flag = true;
    News.addEventListener('click',
        function reunion(){

            if(flag){
                next.style.display= "none";
                flag = false;
            }
            next.style.display= "block";
            flag = true;

        }
    )


    close.addEventListener('click',function(){

            next.style.display = "none";

        }

    )







    function getStyle(obj,attr){

        if(obj.currentStyle){

            return  obj.currentStyle[attr];
        }else{

            return  getComputedStyle(obj,false)[attr];
        }


    }

}